#ifndef	_INPUT_EVENT_H
#define	_INPUT_EVENT_H

//按键设备节点
//#define KEY_INPUT_DEV	"VirtualPS/2 VMware VMMouse"
#define KEY_INPUT_DEV	"USB2IIC_CTP_CONTROL"
#define KEYS_VAL_FILE	"/sys/devices/platform/gpio-keys/keys_val"

//按键键值
#define KEY1	0x02e8
#define KEY2	0x02e9
#define KEY3	0x02ea
#define KEY4	0x02eb

//按键个数
#define KEY_NUM		4

struct key_event {
	int key_val;										//键值
	char *key_name;										//按键名称
	struct timeval press;								//按下的时间
	struct timeval release;								//松开的时间
	void (*key_handle_func)(struct key_event *event);	//回调函数
};

int input_dev_init(void);
void set_key_handle_func(int key_val, void (*key_handle_func)(struct key_event *event));
int get_key_value(int key_val);

//void screen_touch_timeout_detect(void);

#endif	//_INPUT_EVENT_H
